﻿
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
    <title>Geoplaza studenten</title>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <script language="JavaScript" type="text/JavaScript">
        function load_content() {
            if (parent.document.getElementById('main_div')) {
                parent.document.getElementById('main_div').innerHTML = document.getElementById('inner_frame').innerHTML;
            }
            if (!parent.document.getElementById('main_div')) {
                window.location = ('index.html');
            }
        }
	</script>
</head>
<body onload="load_content()">
    <div id="inner_frame">
        <h2>Welkom op de studentenprofiel pagina</h2>
        <p>
        Hier kan je door de studenten heen scrollen (eventueel door middel van een zoekpagina).
        </p>
        <div id="showStudent">
         <p>
       	<?php
		$link = mysql_connect("localhost","root","usbw") ;
		mysql_select_db("geoplaza",$link) ;
		
	   	$query  = "SELECT voornaam , achternaam, woonplaats, email, telefoon, biography FROM studentprofiel";
		$result = mysql_query($query, $link);
		while($row = mysql_fetch_array($result, MYSQL_ASSOC))
		{
			echo "{$row['voornaam']} " .
				 "{$row['achternaam']} <br>" . 
				  "Woonplaats  : {$row['woonplaats']} <br>" .
				  "E-mail : {$row['email']} <br>" .
				  "Biography : {$row['biography']} <br><br>";
		} 
		?> 
		</p>
        </div>
    </div>
</body>
</html>